.ui.form
  = form_for @post do |f|
    .field
      = f.text_field :title,:label=>false,:id=>'post_title',:placeholder=>'请输入标题',:class=>'ui transparent input'
    .field
      = f.text_area :content,:label=>false
    .field
      = f.submit "马上分享文章",:class=>'ui green fluid button'
:javascript
  var editor = new Simditor({
    textarea: $('#post_content'),
    placeholder: '请输入正文',
    defaultImage: '/image.png',
    fileKey: 'upload_file',
    upload: {
      url: '/upload',
      leaveConfirm: '正在上传文件，如果离开上传会自动取消'
    },
    pasteImage: true
  });